package graduationorder.graduationorder.mapper;

import graduationorder.graduationorder.domain.CustomerService;
import graduationorder.graduationorder.domain.User;

import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.ArrayList;

@Mapper
public interface UserMapper {

    public User getUserByEmployeeId(@Param("userName") String userName);
    public int increaseUser(@Param("user") User user);
    public int increaseUserInfo(@Param("user") User user);
    public ArrayList<User> queryUser4Admin(@Param("userName") String userName, @Param("employeeId") String employeeId);
    public User queryUser4Normal(@Param("employeeId") String employeeId);
    public int updateUser(@Param("user") User user);
    public int updateUserInfo(@Param("user") User user);
    public User getUserById(@Param("userId") Integer userId);
    public int deleteUser(@Param("userId") Integer userId);
    public int deleteUserInfo(@Param("employeeId") String employeeId);
    public int modifyPassword(@Param("employeeId") String employeeId, @Param("newPassword") String newPassword);
    public CustomerService getCustomerServiceInfoByName(@Param("name") String name);
}